<!--user login-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" scroll="no">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
	<meta http-equiv="Content-Script-Type" content="text/javascript">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
	
	<title><?php echo $L['kod_name'].$L['kod_power_by'];?></title>
	<link href="<?php echo STATIC_PATH;?>images/common/favicon.ico" rel="Shortcut Icon">
	<link href="<?php echo STATIC_PATH;?>style/common.css?ver=<?php echo KOD_VERSION;?>" rel="stylesheet"/>
	<link href="./static/style/font-awesome/css/font-awesome.css?ver=<?php echo KOD_VERSION;?>" rel="stylesheet">
	<!--[if IE 7]>
	<link rel="stylesheet" href="./static/style/font-awesome/css/font-awesome-ie7.css">
	<![endif]-->
	<link href="<?php echo STATIC_PATH;?>style/login.css?ver=<?php echo KOD_VERSION;?>" rel="stylesheet">
</head>

<body>
	<?php
		$arr = array(2,3,6,8,9,10,12);
		$get = $arr[mt_rand(0,count($arr)-1)];
		$image = STATIC_PATH."images/wall_page/".$get.".jpg";
		echo '<img class="background" src="'.$image.'" />';
		echo '<style type="text/css">.title{background: #6699cc url('.$image.') 0px -92px;}</style>';
	?>
	<div class="init_loading"><div><img src="<?php echo STATIC_PATH;?>images/common/loading_simple.gif"/></div></div>
	<div class="loginbox animated-500 fadeInDown" >
		<div class="title">
			<div class="logo"><i class="icon-cloud"></i><?php echo $L['kod_name'];?></div>
			<div class='info'>——<?php echo $L['kod_name_desc'];?></div>
			<div class="menu_group">
				<a id='footer_language' data-toggle="dropdown" href="javascript:void(0);" class="topbar_menu">
					<i class='font-icon icon-flag'></i>Language<b class="caret"></b>
				</a>
				<ul class="dropdown-menu footer_language pull-left animated menuShow" role="menu" aria-labelledby="footer_language">
				  	<?php 
				  		$tpl = "";
				  		foreach ($config['setting_all']['language'] as $key => $value) {
				  			$name = $value[0];
				  			$select = LANGUAGE_TYPE == $key ? "this":"";
				  			$tpl .= "<li><a href='javascript:core.language(\"{$key}\");' title=\"{$key}/{$value[1]}/{$value[2]}\" class='{$select}'><i class='lang-flag flag-{$key}'></i>{$name}</a></li>";
				  		}
						echo $tpl;
					?>
				</ul>
			</div>
		</div>
		<div class="form">
			<form action="#">
				<div class="inputs">
					<div><span><?php echo $L['username'];?>：</span>
					<input id="username" name='name' type="text" placeholder="<?php echo $L['username'];?>" required autocomplete="on"/>
					</div>
					<div><span><?php echo $L['password'];?>：</span>
					<input id="password" name='password' type="password" placeholder="<?php echo $L['password'];?>" required  autocomplete="on" />
					</div>
	            	<?php if(need_check_code()){?>
					<div class='check_code'>
						<span><?php echo $L['login_code'];?>：</span>
						<input name='check_code' class="check_code" type="text" placeholder="<?php echo $L['login_code'];?>" required autocomplete="off"/>
						<img src='./index.php?user/checkCode' onclick="this.src='./index.php?user/checkCode'" />
						<div style="clear:both;"></div>
					</div>
					<?php }?>
				</div>

				<div class="actions">
					<input type="submit" id="submit" value="<?php echo $L['login'];?>" />
					<input type="checkbox" class="checkbox" name="rember_password" id='rm' checked='checked' />
					<label for='rm'><?php echo $L['login_rember_password'];?></label>
				</div>
				<a href="javascript:void(0);" class="forget_password"><?php echo $L['forget_password'];?></a>
				<div class="msg"><?php echo $msg;?></div>
				<div style="clear:both;"></div>

				<?php if ($this->config['setting_system']['auto_login'] == '1') {?>
				<div class='guest'>
				<a href="./index.php?user/loginSubmit&name=guest&password=guest"><?php echo $L['guest_login'];?><i class=' icon-arrow-right'></i></a>
				</div>
				<?php } ?>
			</form>
		</div>
	</div>
<?php include(TEMPLATE.'common/footer.html');?>
<script type="text/javascript" src="./index.php?share/common_js#id=<?php echo rand_string(8);?>"></script>
<script type="text/javascript" src="<?php echo STATIC_PATH;?>js/lib/seajs/sea.js?ver=<?php echo KOD_VERSION;?>"></script>
<script type="text/javascript" >
	setTimeout(function(){
		if(typeof(seajs) == 'undefined'){
			alert('js文件不完整，请检查文件是否被修改(或服务器提供商压缩js导致文件丢失)');
		}
	},1500);
	seajs.config({
		base: "<?php echo STATIC_PATH;?>js/",
		preload: ["lib/jquery-1.8.0.min"],
		map:[
			[ /^(.*\.(?:css|js))(.*)$/i,'$1$2?ver='+G.version]
		]
	});
	seajs.use("<?php echo STATIC_JS;?>/src/user/main");
</script>
</body>
</html>
